// 在初始加载和路由切换时做一些事情。
export function onRouteChange(props: any) {
  const { matchedRoutes } = props;
  console.log('matchedRoutes', matchedRoutes);
  if (matchedRoutes.length) {
    document.title = matchedRoutes[matchedRoutes.length - 1].route.title || '';
  }
}
